home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Atari Forever 4
/
Atari Forever 4.zip
/
Atari Forever 4.iso
/
SERIE_AI
/
AI_050
/
GREPIT
/
GREPIT.HLP
< prev
next >
Wrap
Text File
|
1998-03-14
|
36KB
|
1,026 lines
≡TABLE OF CONTENTS≡
≡INSTALLATION≡
Disclaimer
As an accessory
As a GEM program
≡ABOUT GREPIT≡
Overview
Support
Credits
≡GETTING STARTED≡
As an accessory
As a GEM program
≡USE OF DIALOG BOXES≡
≡USE OF OUTPUT WINDOW≡
≡THE MAIN DIALOG≡
Paths
Files
Expressions
Options
The Popups (The history function)
≡'EXTENDED OPTIONS' DIALOG≡
≡'SETTINGS' DIALOG≡
≡'FONT' DIALOG≡
≡'COLORS' DIALOG≡
≡'FIND/MARK' DIALOG≡
≡'PRINTER SETTINGS' DIALOG≡
≡'PRINT' DIALOG≡
≡REGULAR EXPRESSIONS≡
≡SPECIAL FEATURES≡
Messages from GREPIT to other programs
Messages from other programs to GREPIT
≡EXAMPLES, TIPS AND TRICKS≡
Converting to and from UNIX
Extracting of strings or comments
Search by using expression files (lists)
GREPIT as a file finder
≡KEYBOARD SHORTCUTS≡
≡HELP ON HELP≡
≡GETTING REGISTERED≡
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡INSTALLATION≡
∙Disclaimer∙
MicroService H. Wierl makes no representation or warranty with respect
to the adequacy of this documentation or the programs which it describes
for any particular purpose or with respect to its adequacy to produce
any particular result. In no event shall MicroService H. Wierl be
liable for special, direct, indirect or consequentional damages, losses,
costs, charges, claims, demands, or claim for lost profits, fees or
expenses of any nature or kind.
You need, at least, the following files to work with GREPIT:
GREPIT.ACC (or GREPIT.PRG or GREPIT.APP)
GREPIT.RSC
GREPIT.HLP
If there's no GREPIT.HLP there's no help period! Got it? Good ...
Just put the three files together in the one (sub-)directory, because
GREPIT loads them from the same directory where it started from. GREPIT
automatically recognizes whether it is an accessory or a normal program.
On Atari TT-models, the TT-Ram-Bits in the program header can (should)
be set for maximum performance (i.e. warp 9.9).
∙As an Accessory∙
Copy GREPIT.PRG (with GREPIT.RSC and GREPIT.HLP of course) to the root
directory of your boot partition and rename it to GREPIT.ACC.
∙As a GEM Program∙
You may copy GREPIT to whatever (sub-)directory you like. Use .PRG or
.APP for the extension.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡ABOUT GREPIT≡
∙Overview∙
The program GREPIT is used for pattern matching and string searching in
files. Through the use of regular expressions GREPIT can provide you
with search patterns however complex they may be. These patterns can be
searched for in all types of files.
GREPIT also provides you with many options to vary or specify search
and output. GREPIT is a powerful tool mainly for those who deal with
many texts, as in the fields of software development or electronic mail
/communication etc.
GREPIT reads files line by line and searches for the pattern. Lines
with possible matches are shown in the output window and written to
the specified output file.
GREPIT lets you easily jump into (and back) the found files just by
clicking on a file path or line number in the output window. Virtual
file loading algorithms reduce memory memory consumption and make it
possible to display files larger than available memory.
GREPIT is (or will soon be) available for various platforms in addition
to Atari TOS as MS-DOS, MS Windows, Windows 95/NT, OS/2, ...
HINT! Don't be surprised if the pattern you are searching for is not
found on the first try. Be especially careful when using regular
expressions, for the outcome may be unexpected!
Please thoroughly analyze your search pattern and the outcoming line,
before you verbally abuse GREPIT. Ha Ha ...
But! If by chance GREPIT misinterprets a regular expression, please
advise us of this and or any other malfunction (hopefully not ;-)).
Many "extras" are featured in this warp speed fast, 110% reliable,
schwarzenegger powerful and easy to relate to, grep utility. But sorry
dude, you must consult this help function from the beginning to the
bitter end to know what the hell we are talking about! So read on and
we'll make it entertaining. It's worth it, believe us ...
∙Support∙
Full support is available to registered users only. Please tell us
your serial number when contacting us with questions or problems.
Error reports or suggestions are welcome.
Our adress is:
MicroService Hermann Wierl
Bahnhofstrasse 8
93336 Altmannstein
GERMANY
MO-FR 9-12 a.m. and 2-5 p.m. CET
Phone : +49-9446-910002
Fax : +49-9446-910003
eMail : 100345.2231@compuserve.com
The latest version of GREPIT is periodically uploaded to CompuServe
(ATARIPRO forum, Library #4 "Utility Programs").
The archive filename should normally be: GREPTTOS.ZIP
∙Credits∙
Special Thanx to:
Rita Bergbauer, for the everything-except-computer-support for one
half of the author team,
Alison Easton, for English language support and the above mentioned
for the second half of the author team as well as explaining some
Beavis and Butthead jokes ;-),
Hermann Weindl, for permanent puzzling over algorithms,
Max Heinzlmeir, for his patience in never ending beta tests,
Gerhard and Martin Huber of Computerislands Bad Gogging for their
fantastic NOVA graphic cards.
Bug reports (especially if you live in Florida - we know how big those
bugs can get) and suggestions for future improvements are welcome and
appreciated! So don't be shy...
That's all folks. C-ya! Wouldn't wanna B-ya!
Wolfgang Schamberger Hermann Wierl
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡GETTING STARTED≡
∙As an Accessory∙
Choose "Grepit" in the accessory menu. Oooops! Of course... duh!
I kill me!
∙As a GEM Program∙
Like every other program you start GREPIT by double clicking on the
icon or the program name on your desktop. Did you expect something
else? Sorry, couldn't resist... a duh!
Did I forget to mention that you first must switch on your computer?
Ok, let's forget this chapter and continue on...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡USE OF DIALOG BOXES≡
Most aspects of dialog boxes can be used also with keyboard. If there is
an underlined character in a selectable object, just press "Alternate"
along with this character. Exceptions to this rule are the [Cancel]
button, which can be activated by the "Undo" key, and the [?] button
which corresponds with the "Help" key.
Since dialog boxes are shown in windows, they are moveable like windows.
Clean 'em from time to time and don't break 'em! (I know, I know, I
don't do windows!)
Edit Fields
You can place the cursor into each edit field by clicking the left mouse
button, using the Up/Down arrow keys or the combination Tab/Shift-Tab.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡USE OF OUTPUT WINDOW≡
It is a standard GEM-Window, which also can be used with the keyboard:
Arrow up : scroll up
Arrow down : scroll down
Arrow right : scroll right
Arrow left : scroll left
Shift and arrow keys: page scroll
ClrHome : beginning of the file
Shift-ClrHome : end of the file
Control-ClrHome : adjust window size to maximum and back
Control-F : find expression in window
Control-G : repeat find
Control-P : print file
Control-U : close window
Control-C : clear output window, free memory
Alt-T : display as text
Alt-B : " as binary file
Alt-H : " with hexadecimal values
Special features:
Double click (left mouse button) on a complete file path:
GREPIT displays this file.
Double click (left mouse button) on a line number:
GREPIT displays this file beginning with this line.
If the double click is neither on a file path nor on a line number,
basically you 're not in Kansas anymore Dorothy! But, GREPIT will
help you out by displaying the "Find" dialog.
You return to the previous file either by double clicking the right
mouse button or the "Undo" key. There's no place like home!
Brackets surrounding the file path in the window title notify you
of reading a subfile not the main file, use this as a reminder.
The above features mentioned can only be used in the main file, not
(yet) in a subfile.
If our shell M>DESK is acivated, you can drag a file from any M>DESK
window and drop it onto the GREPIT window and GREPIT will display the
file. Double clicking on a file path in GREPIT with the right mouse
button passes this file to M>DESK. Other protocolls will be implemented
upon demand.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡THE MAIN DIALOG≡
This dialog is the actual center of GREPIT. Here the search process
starts after the input of source paths, files and expressions. History
popups and the most important options are available here. Batteries
not included! The grep process can be interrupted by pressing either
the 'Left Shift + Right Shift' or 'Control + Left Shift + Alternate'
combination.
∙Paths∙
In this edit field you have to enter the paths (directories) to search
in. You can enter more than one path if you separate them by a semi-
colon. The path specifications hereby follow the standard DOS rules
(i.e. relative and absolute paths etc.). Examples:
C: oder C:\ : Drive C:, starting at the root directory
C:\;D:\;E:\ : Drives C:, D: and E:
\DIR : The directory DIR on the active drive
C:\DIR\ : The directory DIR on drive C:
C:\DIR;C:\DIR2 : The directories DIR and DIR2 on drive C:
You can access the file selector by pressing the [Paths:] button
to choose one or more paths. Leave this function by selecting
[Cancel] in the file selector.
Hint: If you choose a file instead of a path only, the path and the
file name are automatically split by GREPIT and entered into their
appropriate edit fields.
∙Files∙
In this edit field you have to enter the file names or specifications
to search in. The usual DOS jokers like '*' and '?' are possible. You
can enter more than one file or specification by separating them with
a semicolon.
You can access the file selector by pressing the [Files:] button
to choose one or more files. Leave this function by selecting
[Cancel] in the file selector.
∙Expressions∙
GREPIT supports regular expressions known from UNIX operating systems.
Regular expressions are specified by giving special meanings to some
characters, like * or ? in command shells. For more details see "REGULAR
EXPRESSIONS".
NOTE: There are two ways to make GREPIT search for several expressions
at the same time: (Wow Wee Man)
1. Use the OR symbol "|" to separate expressions in the input line.
2. Write all expressions line by line into a file and use the extension
.GRE (GRepit Expressions) for it. Simply type the file's name in the
expression input line and then activate the switch "-f" in the
"Extended Options" dialog.
You can find some examples for expression files in the directory
GRE on the original disk.
An expression file may contain up to 256 lines with a maximum length
of 256 characters each.
You can access the file selector by pressing the [Expressions:] button
to choose an expression file (the given default extension is set to
.GRE). But don't forget to set the -f flag in the extended options.
Otherwise the filename would be interpreted just as a string.
Format of expression files:
--------------------------------------------------------------------
Expression1
Expression2
Expression3|Expression4
...
...
...
Expression256
--------------------------------------------------------------------
∙Options∙ (I think you understand this term)
-b (binary) : Binary data is skipped. Know what I mean Vern?
-d (directory): The subdirectories of the given or current directory
are also searched for.
-r (regular) : Checked : The expression is interpreted as a regular
expression.
Not checked: The expression stays uninterpreted.
NOTE: In binary files the expression always stays
uninterpreted (no regular expression search).
Consider it when entering the expression or
activate the option -b (binary skip).
The OR character is reserved for separating expressions.
If you want to search for this character, you must use
a regular expression for it, which is: "\|".
Example: You search for "||".
Expression = "\|\|"
(The chick translating doesn't get it either so
forgetaboutit!)
-s (sensitive): Capital and small letters are important. So please
pay attention!
-w (word) : There is a match only when the searched for expression is
found as a word, i.e. when the character before AND after
the expression is NOT out of [a-zA-Z0-9_].
Upper/Lower Context
Enter the number of lines you want to see above and below the actual
line found.
You can access a bunch of additional options by using the [Extended
Options] button in the main dialog or the menu item. For description
see "EXTENDED OPTIONS".
∙The Popups∙ (what she likes most, and I'm not talkin' baseball, boys!)
For paths, files and expressions there are two history buttons provided
at the right:
Automatic history function:
The left button. Stores the last inputs automatically; up to 15 lines.
Manual (permanent) history function:
The right button. This popup contains input made by the user.
To store an entry into the permanent history popup, position the cursor
onto paths, files or expressions edit field and press the "Insert" key.
Then just select a free entry in the popup.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'EXTENDED OPTIONS' DIALOG≡
-a (append) : The output is appended to the previous file. For the
meaning of "to append" we recommend Webster's.
-c (count) : Ok 1 2 3 4 5 6 7 8 9 10 ..... Now backwards! Only the total
number of found lines is shown.
Example: C:\DIR\TEST.TXT
15 matches.
-e (extnd.) : Extended output format. The output file will have a
short heading and a small statistic at the end (the
heading at the beginning, of course!!!).
-f (file) : The expressions are taken from a seperate file. Write the
file name into the expression edit line and set this option
(for more details see "Examples, Tips and Tricks").
-h (hide) : Hide and seek? Return to count! The filename is hidden.
Useful for filtering text.
Attention: Option -h excludes the option -l. Logical,
ain't it?
-l (list) : If there is a match you will ONLY get the filename.
Attention: Option -l excludes the option -h.
-m (more) : Length, time and date of the file are added to the filename.
-n (number) : The output lines start with the line number (the number in
the original file of course).
Example:
123: Output line.
With a double click on the line number you can jump right
into the original file to the according position (see "Use
of Output Window").
-p (point) : The output starts at the beginning of the match.
Example: Line read = "Have a nice day!"
search for "nice"
Output = "nice day!"
-u (unix) : We are not talking of unic's! It just means that all lines
in the output file end with LF only instead of CR/LF. That's
useful for transferring files to Unix systems (see Examples,
Tips and Tricks).
-v (verbose): The output is "outputted" on the output device. Well,
actually I just want to say the output that's on the
output device is outputted, too. Get it, got it, good!
I think I need a drink ...
-y (onlY) : The output ends at the end of the match.
Example: Line read = "Have a nice day!"
search for "nice"
Output = "Have a nice"
The combination of -p and -y gives you the match only.
-z (zero) : All lines which do NOT contain the searched for expression
are written into the output file.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'SETTINGS' DIALOG≡
Tabulator size:
Tab's are expanded to this number of characters.
Main dialog at program startup:
If you set this option the main dialog appears automatically after
the program starts. Look how much time we try to save you!
Confirm on exit:
You are asked for confirmation before GREPIT terminates.
3D effects:
The 3D effect can be activated on color resolutions with 16 or more
colors. If you can't deal with it, just shut it off ;-) !
Auto save settings:
The complete settings (input lines, history popups, window positions
etc.) are saved automatically every time you quit the program. A
highly recommended option!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'FONT' DIALOG≡
You can choose the font and its size for the output and help window. If
GDOS is installed, GDOS fonts (except proportional ones) are displayed
and supported.
Hint: Not all GDOS fonts cantain all of the characters. But be opti-
mistic - 10% of the characters aren't missing. You just have 90% to
work with.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'COLORS' DIALOG≡
I didn't know colors could talk. But in this case you can set the colors
for window background, window text, paths, line numbers and expressions
as well as the headlines in the help function.
In reference to colors... Welcome to the 90s. Don't breathe the air.
Don't drink the water. Don't eat fruit, vegetables, meat, fish, sugar,
salt, fats. Don't have sex ever again. No more monochrome resolutions.
Have a nice day!
But we stay old fashioned by letting GREPIT work in monochrome. But
invert found expressions.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'FIND/MARK' DIALOG≡
Come on you know this one (at least the 'Find' part). Just enter the
expression to be found in the output window ... The search always
begins with the first visible line in the window.
If the expression is found, the line will be inverted. If no expression
is entered, all find variables are reset, an inverted line disappears.
The options are common, too:
[Case sensitive]:
Capital and small letters matter.
[Whole Word]:
There is a match only when the searched for expression is found as
a word.
[Regular Expression]:
The expression is interpreted as a regular expression.
The find process can be interrupted by pressing either the
'Left Shift + Right Shift' or 'Control + Left Shift + Alternate'
combination.
You can repeat the search with >Control-G<. In this case search will be
continued with the first visible line in the output window except there
is a found line shown in the window. Then search goes on with the line
after or before this line (depends on the last active search direction).
[Mark only] button: The expression entered in this dialog is highlighted
throughout the output window with the color you have set for expressions
in the "Colors" dialog.
After every grep process the first expression entered in the main
dialog is marked automatically. This feature allows you to quickly
make any expression in the output window visible without starting a
new grep process.
If no expression is entered, no expression will be marked of course.
Tah-Dah!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'PRINTER SETTINGS' DIALOG≡
You can adjust GREPIT to your printer here. Please enter the values
(escape sequences) in decimal numbers, separated by commas. The
sequences in detail:
'Description':
No special meaning, just for information.
'Init Text':
Sent to the printer before everything else. Normally used for
printer reset, font and line settings etc.
'Exit Text':
Sent at the end of printing. Used for form feed and printer reset.
'Init Page', 'Exit Page':
Sequence at every page start and end. The exit page sequence
(usually a form feed = 12) is sent after the number of lines
entered in 'Lines per page' edit field in the "Print" dialog.
If you, for example, don't set a form feed at 'Exit Page', the
value in 'Lines per page' has no effect.
'Init Line', 'Exit Line':
Sequence at every line start and end. For example 5 x the value 32
as init line makes a left border of 5 spaces. For line exit the
standard setting is normally '13,10' (13 = Carriage Return, 10 =
Line Feed).
The remaining 2x8 edit fields are for changing critical characters by
replacing characters with printer sequences.
With [Load] and [Save] you can write (and read from) the printer setting
to a separate file (default extension is *.DRV).
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡'PRINT' DIALOG≡
Print the file presently shown in the output window. You can use the
parallel or serial port. You can also set the number of lines per
page and the number of characters per line.
The print process can be interrupted by pressing either the
'Left Shift + Right Shift' or 'Control + Left Shift + Alternate'
combination.
Hint: If you don't set a form feed in the 'Exit Page' sequence of the
printer setting, the value in 'Lines per page' has no effect, i.e.
the printer ejects the paper by itself and you will always get the
maximum number of lines on a page.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡REGULAR EXPRESSIONS≡
Attention and concentration please, here comes the most difficult part
of this manual. This is our implementation of Regular Expressions:
^ - The circumflex as the first character constrains matches to
the beginning of lines.
Ex.: 1) "^blahblah" matches lines beginning with "blahblah".
2) "^" matches all non-blank lines.
$ - The dollar sign as the last character constrains matches to
the end of lines.
Ex.: 1) "blahblah$" matches lines ending with "blahblah".
2) "^blahblah$" matches lines consisting of the single
word "blahblah".
. - The period represents any single character, like the DOS
wildcard "?".
Ex.: "Hun.er" matches "Hunter", "Hunger" etc.
[a-z] - Character group. Represents any character of this group or
of the given range of characters. Important: A range of
characters must be given in ASCII order (A-Z, a-z, 0-9 etc.).
Ex.: 1) "[0-9]" matches all digits from 0 to 9.
2) "([0-9]+)" matches "(76)", "(56789)", "(4)" etc.
(for the explanation of the "+" specifier read on)
3) "^[A-Z]" matches lines starting with capital letters.
[^a-z] - Negative character group. Represents any character NOT in
this group or not in the given range of characters.
Ex.: "Gre[^py]" matches "Green", "Great" etc. but not
"Grep", "Grey" etc.
? - The preceeding character or the preceeding character
group may occur 0 or 1 times. Not to be mistaken for the
DOS wildcard!
Ex.: "bla?hblah" matches "blhblah" or "blahblah" but not
"blaahblah"
* - The preceeding character or the preceeding character
group may occur 0 or more times.
Ex.: "bla*hblah" matches "blhblah", "blahblah", "blaahblah"
"blaaaahblah" and so on...
+ - The preceeding character or the preceeding character
group may occur 1 or more times.
Ex.: "bla+hbla" matches "blahblah", "blaaaahblah" etc.
\ - Quote next character. This allows all the above mentioned
regular expression specifiers to be searched for.
Ex.: If you want to search for "*" you have to write "\*".
ATTENTION: Search for line separator characters (Carriage Returns and/or
Line Feeds) is not yet supported at this time.
Input of expressions:
You normally just enter the expression(s) in the "Expression(s)" edit
field of the main dialog. But, for very long expressions or many of them
you can use an external expression file. Write all expressions line by
line into a file and use the extension .GRE (GRepit Expressions) for it.
Simply type the file's name in the expression input line of the main
dialog and activate the switch "-f" in the "Extended Options" dialog.
An expression file may contain up to 256 lines with a maximum length
of 256 characters each.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡SPECIAL FEATURES≡
∙Messages from GREPIT to other programs∙
If you double click on a file name or file path with the right mouse
button, GREPIT sends the message GM_SHOW_FILE (8000) to the main
application.
For programmers:
pipe[0] : contains the message ID 8000 (GM_SHOW_FILE).
pipe[3] und pipe[4] : contain a pointer to the file name.
pipe[5] und pipe[6] : contain the number of the line to be displayed,
as a long value.
∙Messages from other programs to GREPIT∙
The above described procedure also works vice versa. If GREPIT receives
the message GM_SHOW_FILE it will display the file.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡EXAMPLES, TIPS AND TRICKS≡
∙Converting to and from UNIX∙
Problem : You have an ASCII file from a UNIX system. UNIX uses only a
LF (Line Feed) for terminating lines, but TOS normally needs
the CR/LF (Carriage Return / Line Feed) combination, therefore
you should convert the file.
Solution: GREPIT can read both types of ASCII files but the output is
always in TOS format. Just enter the UNIX file path/name in
the 'Paths'/'Files' fields, use the regular expression ".*"
which matches all lines and disable all options except the
"Regular Expression" option in the main dialog. After the
grep run save the file with the 'Save as...' function.
Example : Expression(s): .*
or
Problem : You want to transfer TOS ASCII files to UNIX systems.
Solution: Do it like the above mentioned and set the flag -u in the
"Extended Options" dialog. This option lets GREPIT add
only LF instead of CR/LF to line endings.
∙Extracting of C-strings, comments, hex values or functions∙
Problem : You want to extract all strings out of a C-project and you
want to get the strings without the rest of the line.
Solution: Use the regular expression >>>".*"<<< to find all lines
containing anything in quotation marks. To fade out the
rest of the line, set the options -p and -y in the "Extended
Options" dialog.
or
Problem : You want to extract comments in a C-project.
Solution: Use the regular expression >>>/\*.*\*/<<<. Remember: "*" is
a regular expression specifier and you must set a backslash
in front of it to be interpreted as a normal character!
Suggest.: Begin your C-functions with a header, for example:
/*****************************************/
/* Function name: Description */
/*****************************************/
Now you can extract these headers with the above regular
expression.
or
Problem : You want to find all hexadecimal numbers in a C-project.
Solution: Use the regular expression >>>0[xX][0-9a-fA-F]*<<<.
or
Problem : You want to find all functions in a C-project.
Solution: Use >>>^[a-zA-Z][a-zA-Z]* *.*([^;]*)[^;]*$<<<. Confused?
∙Search by using expression files (lists)∙
Problem : You want to extract all calls to GEMDOS functions in your
C-project.
Solution: Write the names of all GEMDOS functions to a seperate text
file (for example GEMDOS.GRE) and set the flag -f in the
extended options dialog. GREPIT will search for all
expressions listed in this file.
There are some sample files in the folder "GRE" of the
original GREPIT archive.
∙GREPIT as a file finder∙
Problem : You need to find a file on your harddisk but you can't
remember the exact name. The partitions on the harddisk are
C:, D:, E: and F:. The file name begins with "A" and has the
extension ".TXT".
Solution: Source(s) : [CDEF]:\A*.TXT
Expression: .*
Flags to be set: -d Search subdirectories
-l List only file names
(The regular expression ".*" matches anything.)
To find all ".TXT", ".DOC" and ".TEX" files on drive C: enter:
Source(s) : C:\*.[TXT|DOC|TEX]
Expression: .*
Flags to be set: -d Search subdirectories
-l List only file names
*** !!! ***
If you have more ideas to utilize GREPIT, let us know! We will collect
and distribute them with GREPIT for the benefit of all GREPIT users.
*** !!! ***
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡KEYBOARD SHORTCUTS≡
∙Basics∙
Basically all elements in a dialog box with a underlined character in
the text can be selected by typing the underlined character combined
with the 'Alternate' key on the keyboard.
The button with the thick black border is the default button and can
be selected by the Return/Enter key.
A [Cancel] button corresponds with the 'Undo' key, a [?] button with
the 'Help' key.
∙In the main dialog∙
'Insert' : To store an entry into a permanent history popup.
∙To break functions∙
'Left Shift + Right Shift' or 'Control + Left Shift + Alternate'
∙In the output window∙
Arrow up : scroll up
Arrow down : scroll down
Arrow right : scroll right
Arrow left : scroll left
Shift and arrow keys: page scroll
ClrHome : beginning of the file
Shift-ClrHome : end of the file
Control-ClrHome : adjust window size to maximum and back
Control-F : find expression in window
Control-G : repeat find
Control-P : print file
Control-U : close window
Control-C : copy active file to clipboard
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡HELP ON HELP≡
The help window can also be used with keyboard shortcuts:
Arrow up : scroll up
Arrow down : scroll down
Arrow right : scroll right
Arrow left : scroll left
Shift and arrow keys: page scroll
ClrHome : beginning of chapter
Shift-ClrHome : end of chapter
Control-ClrHome : adjust window size to maximum and back
Undo : jump to contents
ESC, Control-Q, Control-U or 2 x Undo: Close help.
In the table of contents, a click with the left mouse button on a
chapter headline displays the referring chapter. Return to contents
with a right click anywhere in the help window.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
≡GETTING REGISTERED≡
The program GREPIT is used for pattern matching and string searching in
files. Through the use of regular expressions GREPIT can provide you
with search patterns however complex they may be. These patterns can be
searched for in all types of files.
GREPIT also provides you with many options to vary or specify search
and output. GREPIT is a powerful tool mainly for those who deal with
many texts, as in the fields of software development or electronic mail
/communication etc.
GREPIT lets you easily jump into (and back) the found files just by
clicking on a file path or line number in the output window. Virtual
file loading algorithms reduce memory memory consumption and make it
possible to display files larger than available memory.
GREPIT is (or will soon be) available for various platforms in addition
to Atari TOS as MS-DOS, MS Windows, Windows NT, OS/2, NeXTstep, Apple,
Unix ...
There are NO restrictions in unregistered state. Only the info dialog
will appear at every program startup as an evaluation copy reminder.
There might be a slight delay on program startup especially on slower
machines. This also disappears after registering.
GREPIT is distributed as Shareware. It is not free or Public Domain.
This means you may copy and distribute the unregistered version freely
and use it for evaluation purposes without charge for a period of
30 days. If you use this software beyond the initial evaluation period
the registration fee is required.
----------------------------------------------------------
∙REGISTRATION FEE: US$ 20,--∙
----------------------------------------------------------
or the equivalent amount in your local currency.
Follow these steps for registration:
1) Send us the form ORDER.TXT (E-Mail, FAX or snail mail) with your
adress and way of payment
or
You are a CompuServe member. Then just type GO SWREG and register
online. Enter GREPIT's registration ID #3130 when prompted. The
registration fee will be charged to your CompuServe account.
2) After receiving your payment we will send you your serial number
and registration code.
3) Click on [Register!] in the "...about GREPIT" dialog and enter your
name, serial number and registration code.
And here is our adress:
MicroService Hermann Wierl
Bahnhofstrasse 8
93336 Altmannstein
GERMANY
MO-FR 9-12 a.m. and 2-5 p.m. CET
Phone : +49-9446-910002
Fax : +49-9446-910003
eMail : 100345.2231@compuserve.com
Please note: After successful registration a file named GREPIT.REG is
created with your data. Please don't include this file when copying
because it contains your personal data!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~